
<%@ page import="cn.gudian.cms.System.SysConfig" %>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
        <meta name="layout" content="main" />
        <title><g:message code="sysConfig.edit" default="Edit SysConfig" /></title>
    </head>
    <body>
        <div class="nav">
            <span class="menuButton"><a class="home" href="${createLinkTo(dir: '')}"><g:message code="home" default="Home" /></a></span>
            <span class="menuButton"><g:link class="list" action="list"><g:message code="sysConfig.list" default="SysConfig List" /></g:link></span>
            <span class="menuButton"><g:link class="create" action="create"><g:message code="sysConfig.new" default="New SysConfig" /></g:link></span>
        </div>
        <div class="body">
            <h1><g:message code="sysConfig.edit" default="Edit SysConfig" /></h1>
            <g:if test="${flash.message}">
            <div class="message"><g:message code="${flash.message}" args="${flash.args}" default="${flash.defaultMessage}" /></div>
            </g:if>
            <g:hasErrors bean="${sysConfigInstance}">
            <div class="errors">
                <g:renderErrors bean="${sysConfigInstance}" as="list" />
            </div>
            </g:hasErrors>
            <g:form method="post" >
                <g:hiddenField name="id" value="${sysConfigInstance?.id}" />
                <g:hiddenField name="version" value="${sysConfigInstance?.version}" />
                <div class="dialog">
                    <table>
                        <tbody>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="varName"><g:message code="sysConfig.varName" default="Var Name" />:</label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: sysConfigInstance, field: 'varName', 'errors')}">
                                    <g:textField name="varName" value="${fieldValue(bean: sysConfigInstance, field: 'varName')}" />

                                </td>
                            </tr>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="info"><g:message code="sysConfig.info" default="Info" />:</label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: sysConfigInstance, field: 'info', 'errors')}">
                                    <g:textField name="info" value="${fieldValue(bean: sysConfigInstance, field: 'info')}" />

                                </td>
                            </tr>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="groupID"><g:message code="sysConfig.groupID" default="Group ID" />:</label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: sysConfigInstance, field: 'groupID', 'errors')}">
                                    <g:select name="groupID" from="${sysConfig.constraints.groupID.inList}" value="${sysConfig.groupID}" valueMessagePrefix="sysConfig.groupID"  />

                                </td>
                            </tr>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="varType"><g:message code="sysConfig.varType" default="Var Type" />:</label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: sysConfigInstance, field: 'varType', 'errors')}">
                                    <g:select name="varType" from="${sysConfigInstance.constraints.varType.inList}" value="${sysConfigInstance.varType}" valueMessagePrefix="sysConfig.varType"  />

                                </td>
                            </tr>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="varValue"><g:message code="sysConfig.varValue" default="Var Value" />:</label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: sysConfigInstance, field: 'varValue', 'errors')}">
                                    <g:textField name="varValue" value="${fieldValue(bean: sysConfigInstance, field: 'varValue')}" />

                                </td>
                            </tr>
                        
                        </tbody>
                    </table>
                </div>
                <div class="buttons">
                    <span class="button"><g:actionSubmit class="save" action="update" value="${message(code: 'update', 'default': 'Update')}" /></span>
                    <span class="button"><g:actionSubmit class="delete" action="delete" value="${message(code: 'delete', 'default': 'Delete')}" onclick="return confirm('${message(code: 'delete.confirm', 'default': 'Are you sure?')}');" /></span>
                </div>
            </g:form>
        </div>
    </body>
</html>
